<template>
  <div class="purseDetail">
    <uv-gap height="12rpx" bgColor="#F8F8F8"></uv-gap>
    <view v-if="list.length>0" class="total_Detail">

      <view v-for="item in list" :key="item" class="item">
       <view class="date">{{item.cashOutTime}}</view>

       <view class="tx">
        <span>提现</span>
        &nbsp;
        <span class="color_Ref">￥{{item.cashOut}}</span>
       </view>
      </view>

    </view>
    <view v-else class="jf_detail_none">暂无积分明细</view>
  </div>
</template>

<script setup>
import { onShow } from "@dcloudio/uni-app";
import { ref } from "vue";
import {list as listData} from '../https/api/purseDetail'
let size = ref(20)
let getListdata = async() => {
let res = await listData({
  status:1,
  size:size.value,
  current:1,
})
list.value = res.records.map(v=>{
  return {
    ...v,
    cashOutTime:v.finishTime,
    cashOut:v.amount,
  }
})

}
onShow(async()=>{
  
  // list.value = JSON.parse(uni.getStorageSync('detailList'))
  getListdata()
})

let list = ref([
 
])

</script>

<style lang="scss" scoped>
.jf_detail_none{
  position: fixed;
  top: 50%;

  left: 50%;
  transform: translate(-50%, -50%);


  font-family: Microsoft YaHei;
font-weight: 400;
font-size: 30rpx;
color: #A7A7A7;

}
.purseDetail{
  min-height: 100vh;
 background: #F8F8F8;
}

.total_Detail{
 background: white;

  .color_Ref{
  color: red
  ;

  }
.item{
  font-family: Microsoft YaHei;
font-weight: 400;
font-size: 24rpx;
color: #000000;

  padding: 20rpx 30rpx;
  display: flex;

  justify-content: space-between;
  border-bottom:1px solid #eee ;
}
}
</style>